home *** CD-ROM | disk | FTP | other *** search
/ Aminet 48 / Aminet 48 (2002)(GTI - Schatztruhe)[!][Apr 2002].iso / Aminet / text / edit / vim60rt.lha / Vim / vim60 / ftplugin / perl.vim < prev    next >
Encoding:
Text File  |  2001-09-20  |  1.4 KB  |  46 lines

  1. " Vim filetype plugin file
  2. " Language:    Perl
  3. " Maintainer:    Dan Sharp <vimuser@crosswinds.net>
  4. " Last Change:    Wed, 19 Sep 2001 16:29:01 Eastern Daylight Time
  5. " Current version is at http://sites.netscape.net/sharppeople/vim/ftplugin
  6.  
  7. if exists("b:did_ftplugin") | finish | endif
  8. let b:did_ftplugin = 1
  9.  
  10. " Set 'formatoptions' to break comment lines but not other lines,
  11. " and insert the comment leader when hitting <CR> or using "o".
  12. setlocal fo-=t fo+=croql
  13.  
  14. setlocal com=:#
  15.  
  16. " Make sure the continuation lines below do not cause problems in
  17. " compatibility mode.
  18. set cpo-=C
  19.  
  20. " Change the browse dialog on Win32 to show mainly Perl-related files
  21. if has("gui_win32") && !exists("b:browsefilter")
  22.     let b:browsefilter = "Perl Source Files (*.pl)\t*.pl\n" .
  23.                \ "Perl Modules (*.pm)\t*.pm\n" .
  24.                \ "Perl Documentation Files (*.pod)\t*.pod\n" .
  25.                \ "All Files (*.*)\t*.*\n"
  26. endif
  27.  
  28. " Provided by Ned Konz <ned@bike-nomad.com>
  29. "---------------------------------------------
  30. setlocal include=\\<\\(use\|require\\)\\s*
  31. setlocal includeexpr=substitute(substitute(v:fname,'::','/','g'),'$','.pm','')
  32. setlocal iskeyword=48-57,_,A-Z,a-z,:
  33. setlocal define=[^A-Za-z_]
  34.  
  35. " Set this once, globally.
  36. if !exists("perlpath")
  37.   if &shellxquote != '"'
  38.     let perlpath = system('perl -e "print join(q/,/,@INC)"')
  39.   else
  40.     let perlpath = system("perl -e 'print join(q/,/,@INC)'")
  41.   endif
  42.   let perlpath = substitute(perlpath,',.$',',,','')
  43. endif
  44.  
  45. let &l:path=perlpath
  46.